// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima).
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

/*!
 * @file satellite_info.h
 * This header file contains the declaration of the described types in the IDL file.
 *
 * This file was generated by the tool gen.
 */

#ifndef _SATELLITE_INFO_H_
#define _SATELLITE_INFO_H_

// TODO Poner en el contexto.

#include <stdint.h>
#include <array>
#include <string>
#include <vector>
#include <map>
#include <bitset>

#if defined(_WIN32)
#if defined(EPROSIMA_USER_DLL_EXPORT)
#define eProsima_user_DllExport __declspec( dllexport )
#else
#define eProsima_user_DllExport
#endif
#else
#define eProsima_user_DllExport
#endif

#if defined(_WIN32)
#if defined(EPROSIMA_USER_DLL_EXPORT)
#if defined(satellite_info_SOURCE)
#define satellite_info_DllAPI __declspec( dllexport )
#else
#define satellite_info_DllAPI __declspec( dllimport )
#endif // satellite_info_SOURCE
#else
#define satellite_info_DllAPI
#endif
#else
#define satellite_info_DllAPI
#endif // _WIN32

namespace eprosima
{
    namespace fastcdr
    {
        class Cdr;
    }
}


const uint8_t satellite_info__SAT_INFO_MAX_SATELLITES = 20;
typedef std::array<uint8_t, 20> satellite_info__octet_array_20;
/*!
 * @brief This class represents the structure satellite_info defined by the user in the IDL file.
 * @ingroup SATELLITE_INFO
 */
class satellite_info
{
public:

    /*!
     * @brief Default constructor.
     */
    eProsima_user_DllExport satellite_info();

    /*!
     * @brief Default destructor.
     */
    eProsima_user_DllExport ~satellite_info();

    /*!
     * @brief Copy constructor.
     * @param x Reference to the object satellite_info that will be copied.
     */
    eProsima_user_DllExport satellite_info(const satellite_info &x);

    /*!
     * @brief Move constructor.
     * @param x Reference to the object satellite_info that will be copied.
     */
    eProsima_user_DllExport satellite_info(satellite_info &&x);

    /*!
     * @brief Copy assignment.
     * @param x Reference to the object satellite_info that will be copied.
     */
    eProsima_user_DllExport satellite_info& operator=(const satellite_info &x);

    /*!
     * @brief Move assignment.
     * @param x Reference to the object satellite_info that will be copied.
     */
    eProsima_user_DllExport satellite_info& operator=(satellite_info &&x);

    /*!
     * @brief This function sets a value in member timestamp_
     * @param _timestamp_ New value for member timestamp_
     */
    eProsima_user_DllExport void timestamp_(uint64_t _timestamp_);

    /*!
     * @brief This function returns the value of member timestamp_
     * @return Value of member timestamp_
     */
    eProsima_user_DllExport uint64_t timestamp_() const;

    /*!
     * @brief This function returns a reference to member timestamp_
     * @return Reference to member timestamp_
     */
    eProsima_user_DllExport uint64_t& timestamp_();

    /*!
     * @brief This function sets a value in member count_
     * @param _count_ New value for member count_
     */
    eProsima_user_DllExport void count_(uint8_t _count_);

    /*!
     * @brief This function returns the value of member count_
     * @return Value of member count_
     */
    eProsima_user_DllExport uint8_t count_() const;

    /*!
     * @brief This function returns a reference to member count_
     * @return Reference to member count_
     */
    eProsima_user_DllExport uint8_t& count_();

    /*!
     * @brief This function copies the value in member svid
     * @param _svid New value to be copied in member svid
     */
    eProsima_user_DllExport void svid(const satellite_info__octet_array_20 &_svid);

    /*!
     * @brief This function moves the value in member svid
     * @param _svid New value to be moved in member svid
     */
    eProsima_user_DllExport void svid(satellite_info__octet_array_20 &&_svid);

    /*!
     * @brief This function returns a constant reference to member svid
     * @return Constant reference to member svid
     */
    eProsima_user_DllExport const satellite_info__octet_array_20& svid() const;

    /*!
     * @brief This function returns a reference to member svid
     * @return Reference to member svid
     */
    eProsima_user_DllExport satellite_info__octet_array_20& svid();
    /*!
     * @brief This function copies the value in member used
     * @param _used New value to be copied in member used
     */
    eProsima_user_DllExport void used(const satellite_info__octet_array_20 &_used);

    /*!
     * @brief This function moves the value in member used
     * @param _used New value to be moved in member used
     */
    eProsima_user_DllExport void used(satellite_info__octet_array_20 &&_used);

    /*!
     * @brief This function returns a constant reference to member used
     * @return Constant reference to member used
     */
    eProsima_user_DllExport const satellite_info__octet_array_20& used() const;

    /*!
     * @brief This function returns a reference to member used
     * @return Reference to member used
     */
    eProsima_user_DllExport satellite_info__octet_array_20& used();
    /*!
     * @brief This function copies the value in member elevation
     * @param _elevation New value to be copied in member elevation
     */
    eProsima_user_DllExport void elevation(const satellite_info__octet_array_20 &_elevation);

    /*!
     * @brief This function moves the value in member elevation
     * @param _elevation New value to be moved in member elevation
     */
    eProsima_user_DllExport void elevation(satellite_info__octet_array_20 &&_elevation);

    /*!
     * @brief This function returns a constant reference to member elevation
     * @return Constant reference to member elevation
     */
    eProsima_user_DllExport const satellite_info__octet_array_20& elevation() const;

    /*!
     * @brief This function returns a reference to member elevation
     * @return Reference to member elevation
     */
    eProsima_user_DllExport satellite_info__octet_array_20& elevation();
    /*!
     * @brief This function copies the value in member azimuth
     * @param _azimuth New value to be copied in member azimuth
     */
    eProsima_user_DllExport void azimuth(const satellite_info__octet_array_20 &_azimuth);

    /*!
     * @brief This function moves the value in member azimuth
     * @param _azimuth New value to be moved in member azimuth
     */
    eProsima_user_DllExport void azimuth(satellite_info__octet_array_20 &&_azimuth);

    /*!
     * @brief This function returns a constant reference to member azimuth
     * @return Constant reference to member azimuth
     */
    eProsima_user_DllExport const satellite_info__octet_array_20& azimuth() const;

    /*!
     * @brief This function returns a reference to member azimuth
     * @return Reference to member azimuth
     */
    eProsima_user_DllExport satellite_info__octet_array_20& azimuth();
    /*!
     * @brief This function copies the value in member snr
     * @param _snr New value to be copied in member snr
     */
    eProsima_user_DllExport void snr(const satellite_info__octet_array_20 &_snr);

    /*!
     * @brief This function moves the value in member snr
     * @param _snr New value to be moved in member snr
     */
    eProsima_user_DllExport void snr(satellite_info__octet_array_20 &&_snr);

    /*!
     * @brief This function returns a constant reference to member snr
     * @return Constant reference to member snr
     */
    eProsima_user_DllExport const satellite_info__octet_array_20& snr() const;

    /*!
     * @brief This function returns a reference to member snr
     * @return Reference to member snr
     */
    eProsima_user_DllExport satellite_info__octet_array_20& snr();
    /*!
     * @brief This function copies the value in member prn
     * @param _prn New value to be copied in member prn
     */
    eProsima_user_DllExport void prn(const satellite_info__octet_array_20 &_prn);

    /*!
     * @brief This function moves the value in member prn
     * @param _prn New value to be moved in member prn
     */
    eProsima_user_DllExport void prn(satellite_info__octet_array_20 &&_prn);

    /*!
     * @brief This function returns a constant reference to member prn
     * @return Constant reference to member prn
     */
    eProsima_user_DllExport const satellite_info__octet_array_20& prn() const;

    /*!
     * @brief This function returns a reference to member prn
     * @return Reference to member prn
     */
    eProsima_user_DllExport satellite_info__octet_array_20& prn();

    /*!
     * @brief This function returns the maximum serialized size of an object
     * depending on the buffer alignment.
     * @param current_alignment Buffer alignment.
     * @return Maximum serialized size.
     */
    eProsima_user_DllExport static size_t getMaxCdrSerializedSize(size_t current_alignment = 0);

    /*!
     * @brief This function returns the serialized size of a data depending on the buffer alignment.
     * @param data Data which is calculated its serialized size.
     * @param current_alignment Buffer alignment.
     * @return Serialized size.
     */
    eProsima_user_DllExport static size_t getCdrSerializedSize(const satellite_info& data, size_t current_alignment = 0);


    /*!
     * @brief This function serializes an object using CDR serialization.
     * @param cdr CDR serialization object.
     */
    eProsima_user_DllExport void serialize(eprosima::fastcdr::Cdr &cdr) const;

    /*!
     * @brief This function deserializes an object using CDR serialization.
     * @param cdr CDR serialization object.
     */
    eProsima_user_DllExport void deserialize(eprosima::fastcdr::Cdr &cdr);



    /*!
     * @brief This function returns the maximum serialized size of the Key of an object
     * depending on the buffer alignment.
     * @param current_alignment Buffer alignment.
     * @return Maximum serialized size.
     */
    eProsima_user_DllExport static size_t getKeyMaxCdrSerializedSize(size_t current_alignment = 0);

    /*!
     * @brief This function tells you if the Key has been defined for this type
     */
    eProsima_user_DllExport static bool isKeyDefined();

    /*!
     * @brief This function serializes the key members of an object using CDR serialization.
     * @param cdr CDR serialization object.
     */
    eProsima_user_DllExport void serializeKey(eprosima::fastcdr::Cdr &cdr) const;

private:
    uint64_t m_timestamp_;
    uint8_t m_count_;
    satellite_info__octet_array_20 m_svid;
    satellite_info__octet_array_20 m_used;
    satellite_info__octet_array_20 m_elevation;
    satellite_info__octet_array_20 m_azimuth;
    satellite_info__octet_array_20 m_snr;
    satellite_info__octet_array_20 m_prn;
};

#endif // _SATELLITE_INFO_H_